import React from 'react';

import './index.scss';

class LinkMe extends React.Component {
  constructor(props) {
    super(props);
    this.state = {
      showWeichat: false,
    }
    this.showWeichat = this.showWeichat.bind(this)
  }
  showWeichat() {
    this.setState({
      showWeichat: !this.state.showWeichat,
    })
  }
  render() {
    return (
      <div className="link-me">
        <span className="title-text">
          联系我
        </span>
        <div className="link-box">
          <ul>
            <li>
              <a href="#" className="tell">
                我的电话
              </a>
            </li>
            <li>
              <a href="mailto:2433823665@qq.com" className="email">
                我的邮箱
              </a>
            </li>
            <li>
              <a href="tencent://message/?uin=2433823665&Menu=yes" target="blank" className="qq">
                我的QQ
              </a>
            </li>
            <li>
              <a href="#" className="weichat" onClick={this.showWeichat}>
                我的微信
              </a>
              <span className={!this.state.showWeichat ? 'wei-chat-img' : 'wei-chat-img active'} onClick={this.showWeichat} />
            </li>
          </ul>
        </div>
      </div>
    )
  }
}
export default LinkMe;
